package net.cloudcodex.shared.dto.campaign.character;

import java.io.Serializable;
import java.util.HashMap;
import java.util.Map;

/**
 * A character, may be playable or not.
 * 
 * @author Thomas
 */
public class CharacterHeaderDTO implements Serializable {

	/**
	 * Id of the character.
	 */
	private long id;
	
	/**
	 * Name of the character or alias (if exists) when seen by player.
	 */
	private String name;

	/**
	 * Character aliases <b>in the scene</b>, only GM can view this.
	 * Alias associated to null key is the global alias in scene.
	 * It mays contain one global alias and one or many specific aliases.
	 * If this CharacterHeaderDTO is not extracted from SceneDTO the aliases
	 * are null and you should look at CharacterDescription#aliases instead.
	 */
	private Map<Long, String> aliases = new HashMap<Long, String>();
	
	/**
	 * Owner's id. If null, it's a NPC or you're not authorized to see it.
	 */
	private Long owner;
	
	/**
	 * Owner's name, same at {@link #owner}.
	 */
	private String ownerNickname;

	/**
	 * public description of the character.
	 */
	private String description;
	
	/**
	 * Icon URL.
	 */
	private String icon;
	
	/**
	 * <code>true</code> if the character is dead, may be null if you're not
	 * the Game Master.
	 */
	private Boolean dead;

	/**
	 * <code>true</code> if the character is locked, may be null if you're not
	 * the Game Master.
	 */
	private Boolean locked;
	
	/**
	 * True if the character is profile.
	 * Players can know that because they cannot make notes on a profile.
	 */
	private boolean profile;
	
	/**
	 * @return the id
	 */
	public long getId() {
		return id;
	}

	/**
	 * @param id the id to set
	 */
	public void setId(long id) {
		this.id = id;
	}

	/**
	 * @return the name
	 */
	public String getName() {
		return name;
	}

	/**
	 * @param name the name to set
	 */
	public void setName(String name) {
		this.name = name;
	}

	/**
	 * @return the description
	 */
	public String getDescription() {
		return description;
	}

	/**
	 * @param description the description to set
	 */
	public void setDescription(String description) {
		this.description = description;
	}

	/**
	 * @return the icon
	 */
	public String getIcon() {
		return icon;
	}

	/**
	 * @param icon the icon to set
	 */
	public void setIcon(String icon) {
		this.icon = icon;
	}

	/**
	 * @return the owner
	 */
	public Long getOwner() {
		return owner;
	}

	/**
	 * @param owner the owner to set
	 */
	public void setOwner(Long owner) {
		this.owner = owner;
	}

	/**
	 * @return the ownerNickname
	 */
	public String getOwnerNickname() {
		return ownerNickname;
	}

	/**
	 * @param ownerNickname the ownerNickname to set
	 */
	public void setOwnerNickname(String ownerNickname) {
		this.ownerNickname = ownerNickname;
	}

	/**
	 * @return the dead
	 */
	public Boolean getDead() {
		return dead;
	}

	/**
	 * @param dead the dead to set
	 */
	public void setDead(Boolean dead) {
		this.dead = dead;
	}

	/**
	 * @return the locked
	 */
	public Boolean getLocked() {
		return locked;
	}

	/**
	 * @param locked the locked to set
	 */
	public void setLocked(Boolean locked) {
		this.locked = locked;
	}

	/**
	 * @return the aliases
	 */
	public Map<Long, String> getAliases() {
		return aliases;
	}

	/**
	 * @param aliases the aliases to set
	 */
	public void setAliases(Map<Long, String> aliases) {
		this.aliases = aliases;
	}

	/**
	 * @return the profile
	 */
	public boolean isProfile() {
		return profile;
	}

	/**
	 * @param profile the profile to set
	 */
	public void setProfile(boolean profile) {
		this.profile = profile;
	}
}
